<!doctype html>
<html lang="en" data-bs-theme="auto">

<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <meta name="description" content="">
  <title>首页</title>

  <link href="/assets/dist/css/bootstrap.min.css" rel="stylesheet">
  <link rel="stylesheet" href="/assets/icons/font/bootstrap-icons.css">

  <link href="/css/dashboard.css" rel="stylesheet">

</head>

<body>

  <div class="container-fluid">

    <h5 class="card-title mt-2">网站管理</h5>
    <hr>
    <div class="row p-3">
      <div class="col-10">
        <table class="table table-bordered">

          <tbody>
            <tr>
              <th>#</th>
              <td>公司</td>
              <td>网站名称</td>
              <th>域名</th>
              <th>状态</th>
              <th>管理账号</th>
              <th>操作</th>
            </tr>
            <%c for(auto &a:obj["infos"].as_array()){ %>
            <tr>
              <td><%c echo<<a.second["sid"].to_string(); %></td>
              <td><%c echo<<a.second["companyname"].to_string(); %></td>
              <td><%c echo<<a.second["sitename"].to_string(); %></td>
              <td><%c echo<<a.second["sitedomain"].to_string(); %></td>
              <td><%c if(a.second["isopen"].to_int()==1){ %>启用<%c }else{ %>关闭<%c } %></td>
              <td><a href="/superadmin/listuser?sid=<%c echo<<a.second["sid"].to_string(); %>">管理账号</a></td>
              <td><a href="/superadmin/editsiteinfo?sid=<%c echo<<a.second["sid"].to_string(); %>">编辑</a> | <a href="/superadmin/deletesiteinfo?sid=<%c echo<<a.second["sid"].to_string(); %>">删除</a></td>
            </tr>
            <%c } %>
          </tbody>

        </table>
      </div>
    </div>

  </div>

  <script src="/assets/dist/js/bootstrap.bundle.min.js"></script>
</body>

</html>